import request from "../utils/request";

export const getContractsByCondition=(param)=>{
    return request({
        url:"contract/list",
        method:"get",
        params:param
    })
}
export const addContract=(param)=>{
    return request({
        url:"contract/add",
        method:"post",
        params:param
    })
}
export const editContract=(param)=>{
    return request({
        url:"contract/edit",
        method:"post",
        data:param
    })
}

export const changeContractActive=(param)=>{
    return request({
        url:"contract/changeContractActive",
        method:"post",
        data:param
    })
}

export const delContract=(param)=>{
    return request({
        url:"contract/delContract",
        method:"post",
        data:param
    })
}
export const getCancelContract=(param)=>{
    return request({
        url:"contract/getCancelContract",
        method:"get",
        params:param
    })
}
export const reStart=(param)=>{
    return request({
        url:"contract/reStart",
        method:"post",
        data:"contractName="+param
    })
}

